package com.ruoyi.system.domain.dto;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.util.Date;

/**
 * 每日用电情况对象 day_elec_info
 *
 * @author handsome
 * @date 2024-07-03
 */
@ApiModel(value = "ElecInfoDto", description = "用户用电量新增信息")
public class ElecInfoDto {//  extends BaseEntity
    private static final long serialVersionUID = 1L;

    /**
     * 用户ID
     */
    @ApiModelProperty(value = "用户ID",notes = "用户身份",example = "1",required = true)
    private Long userId;

    /**
     * 当天用电示数
     */
    @ApiModelProperty(value = "用电量",notes = "用户当天用电数",example = "12",required = true)
    private Long eUsage;

    /**
     * 当天日期
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @ApiModelProperty(value = "当天日期",notes = "用户用电日期",example = "2024-6-30",required = true)
    private Date eTime;

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public Long getUserId() {
        return userId;
    }

    public void seteUsage(Long eUsage) {
        this.eUsage = eUsage;
    }

    public Long geteUsage() {
        return eUsage;
    }

    public void seteTime(Date eTime) {
        this.eTime = eTime;
    }

    public Date geteTime() {
        return eTime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("userId", getUserId())
                .append("eUsage", geteUsage())
                .append("eTime", geteTime())
                .toString();
    }
}
